package com.itheima.day11.myOtherio.test1;

import java.io.FileOutputStream;
import java.io.IOException;
import java.io.ObjectOutputStream;

public class ObjectOutputStreamTest {
    public static void main(String[] args) throws IOException {
        User u = new User();
        u.setUsername("aidmi123");
        u.setPassword("1577724623");

        ObjectOutputStream oos = new ObjectOutputStream(new FileOutputStream("myCode\\src\\com\\itheima\\day11\\g.txt"));
        oos.writeObject(u);
        oos.close();

    }
}
